package com.fp.voiceshoper.utils;

import android.content.Context;
import android.content.SharedPreferences;
import android.os.Vibrator;
import android.preference.PreferenceManager;

public final class Vibro {

	public static void vibrate(Context context, long milis){
		SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context.getApplicationContext());
		if (prefs.getBoolean("vibro", true)){
			Vibrator v = (Vibrator) context.getSystemService(Context.VIBRATOR_SERVICE);
			v.vibrate(milis);	
		}
	
	}
}
